import store from '@/store'
import { compareVersion } from '@/utils'
export function isPassVersion (ver) {
  const v1 = store.getters.appInfo.version
  return compareVersion(v1, ver) !== -1
}
export function isPassVersionByApp (obj) {
  const appId = store.getters.appInfo.appID
  console.log(appId)
  const item = obj[appId]
  if (!item) return false
  if (!item.maxV) {
    return isPassVersion(item.v)
  } else {
    return isPassVersion(item.v) && !isPassVersion(item.maxV)
  }
}
